using System;
using System.Web;
using System.Web.Services;
using System.Web.Services.Protocols;
using Microsoft.Practices.EnterpriseLibrary.Data;
using Model;
using System.Data.SqlClient;


[WebService(Namespace = "http://tempuri.org/")]
[WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
public class Usuarios : System.Web.Services.WebService
{
    public Usuarios() {

        //Uncomment the following line if using designed components 
        //InitializeComponent(); 
    }

    [WebMethod]
    public bool Autenticar(String strLogin , String strSenha) 
    {
        Model.Usuario.RetornaUsuario(strLogin, strSenha);
        return false;
    }

    [WebMethod]
    public bool Criar(String strLogin, String strSenha , String strNome , bool bolAdmin)
    {
        // insiro na base. a senha ja vem em md5
        Model.Usuario.Criar(strNome, strLogin, strSenha, bolAdmin);
        return false;
    }
    

}
